import { request } from '@/utils/request.js'

// 查询账号列表
export function getPhoneinfoList(query) {
  return request({
    url: 'cloud/phoneinfo/index',
    method: 'get',
    params: query
  })
}
// 查询项目列表
export function getProjectList(query) {
  return request({
    url: 'cloud/project/index',
    method: 'get',
    params: query
  })
}
// 改变账号状态
export function changeStatus(query) {
  return request({
    url: 'cloud/phoneinfo/changeStatus',
    method: 'put',
    data: query
  })
}
// 批量改变账号状态
export function changeStatusList(query) {
  return request({
    url: 'cloud/phoneinfo/batchChangeStatus',
    method: 'put',
    data: query
  })
}
// 删除账号
export function deleteAccount(query) {
  return request({
    url: 'cloud/phoneinfo/delete',
    method: 'delete',
    data: query
  })
}
// 分配账号给客户
export function setAssignToClient(query) {
  return request({
    url: 'cloud/phoneinfo/assignToClient',
    method: 'post',
    data: query
  })
}
// 获取账号数量
export function getAmountList(query) {
  return request({
    url: 'cloud/phoneinfo/getAmount',
    method: 'get',
    params: query
  })
}
